#include<bits/stdc++.h>
using namespace std;
const int MAXN=1e5+10;
int n;
int ans=0;
int r[MAXN];
bool vis[MAXN];
bool attack[MAXN];
int main(){
    freopen("duel.in","r",stdin);
    freopen("duel.out","w",stdout);
    ios::sync_with_stdio(false);
    cin>>n;
    memset(vis,1,sizeof(vis));
    memset(attack,1,sizeof(attack));
    for(int i=1;i<=n;i++){
        cin>>r[i];
    }
    r[n+1]=1e6;
    sort(r+1,r+1+n);
    for(int i=1;i<n;i++){
        int pos=upper_bound(r+1,r+n+2,r[i])-r;
        if(pos==n+1)continue;
        while(!attack[pos])pos++;
        if(pos==n+1)continue;
        else{
            vis[i]=0;
            attack[pos]=0;
        }
    }
    for(int i=1;i<=n;i++){
        ans+=(int)vis[i];
    }
    cout<<ans<<endl;
    return 0;
}
